/*
 * Copyright(C) 2010 the original author or authors.
 *
 * Change History Log
 * ----------------------------------------------------
 * Version: 1.0
 * Date: 2011-5-29
 * Author: wangzl
 * ----------------------------------------------------
 */
package com.seemsea.entity.admin.coupon;

import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import com.seemsea.dao.IGenericEntity;
import com.seemsea.entity.admin.BaseEntity;

/**
 * 
 * 
 * @author wangzl
 * @since 2011-5-29
 */
@Entity
@Table(name="coupon_couponitem")
public class CouponItem  extends BaseEntity implements IGenericEntity<Integer>{
	/**
	 * 
	 */
	private static final long serialVersionUID = 3737844473509762703L;
	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	private Integer code;
	private String url;
	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "couponCode")
	private Coupon coupon;

	public Integer getCode() {
		return code;
	}

	public void setCode(Integer code) {
		this.code = code;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public Coupon getCoupon() {
		return coupon;
	}

	public void setCoupon(Coupon coupon) {
		this.coupon = coupon;
	}
}
